package com.bruceliu.service.impl;

import com.bruceliu.bean.Desk;
import com.bruceliu.mapper.DeskMapper;
import com.bruceliu.service.DeskService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @BelongsProject: RestaurantSystem
 * @BelongsPackage: com.bruceliu.service.impl
 * @Author: bruceliu
 * @QQ:1241488705
 * @CreateTime: 2020-02-29 10:04
 * @Description: TODO
 */
@Service
public class DeskServiceImpl implements DeskService {

    @Resource
    DeskMapper deskMapper;

    @Override
    public List<Desk> getDesks(Desk desk) {
        return deskMapper.getDesks(desk);
    }

    @Override
    public int addDesk(Desk desk) {
        return deskMapper.addDesk(desk);
    }

    @Override
    public int deleteDesk(int id) {
        return deskMapper.deleteDesk(id);
    }

    @Override
    public int changeState(Desk desk) {
        return deskMapper.changeState(desk);
    }

    @Override
    public Desk getById(int id) {
        return deskMapper.getById(id);
    }
}
